#define _CRT_SECURE_NO_WARNINGS 1
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define endl '\n'
int ans, num[100];

int main() {
	ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
	int n; cin >> n;
	int res = 0;
	for (int bit = 1; bit <= n; bit *= 10) {
		res = (n / bit) % 10;
		ans = max(ans, res);
		for (int i = 1; i <= res; i++) num[i] += bit;
	}
	cout << ans << endl;
	for (; ans >= 1; ans--) cout << num[ans] << " ";
	cout << endl;
	return 0;
}